<?php
/**
 * Enter description here ...
 * @author Micou13630
 *
 */
class TabSet extends Canvas implements IRenderable {
	protected $animateTabScrolling;
	
	protected $canCloseTabs;
	protected $closeTabIcon;
	protected $closeTabIconSize;
	protected $destroyPanes;
	
	protected $canEditTabTitles;
	protected $titleEditEvent;
	
	protected $showMoreTab;
	protected $moreTabCount;
	protected $moreTabImage;
	protected $moreTabPaneDefaults;
	protected $moreTabTitle;
	
	protected $paneContainerClassName;
	protected $paneContainerOverflow;
	protected $paneMargin;
	
	protected $showTabPicker;
	protected $pickerButtonHSrc;
	protected $pickerButtonVSrc;
	protected $pickerButtonSize;
	protected $pickerButtonSrc;
	
	protected $showTabScroller;
	protected $scrollerButtonSize;
	protected $scrollerHSrc;
	protected $scrollerVSrc;
	protected $scrollerSrc;
	
	protected $skinImgDir;
	
	protected $tabBarAlign;
	protected $tabBarControls;
	protected $tabBarPosition;
	protected $tabBarThickness;
	
	protected $tabs;
	
	
	protected $selectedTab;
	
	
	/**
	 * Constructeur
	 * @param unknown_type $id
	 */
	public function TabSet($id) {
		parent::Canvas($id);
		
		$this->tabs = array();
	}
	
	/**
	 * Permet d'ajouter une tab
	 * @param Tab $t
	 */
	public function addTab(Tab $t) {
		$this->tabs[] = $t;
	}
	
	/**
	 * Implementation de object
	 * @see IRenderable::object()
	 */
	public function object() {
		return get_class($this);
	}

	/**
	 * Implementation de scLog
	 * @see IRenderable::properties()
	 */
	public function properties() {
		return parent::getProp($this);
	}

	/**
	 * Implementation de scLog
	 * @see IRenderable::scLog()
	 */
	public function scLog() {
		ScCollectionLog::getInstance()->addSc(new ScLog($this->object(), get_object_vars($this)));
	}
	
	/**
	 * Implementation de render
	 * @see IScreen::render()
	 */
	public function render() {
		$this->scLog();
		return "isc.".$this->object().".create({".$this->properties()."})";
	}
}

/**
 * Enter description here ...
 * @author Micou13630
 *
 */
class Tab extends Bones implements IRenderable {
	protected $ID;
	
	protected $canClose;
	protected $closeIcon;
	protected $closeIconSize;
	
	protected $canEditTitle;
	
	protected $disabled;
	
	protected $icon;
	protected $iconHeight;
	protected $iconWidth;
	protected $iconSize;
	
	protected $pane;
	
	protected $pickerTitle;
	protected $prompt;
	protected $title;
	
	protected $width;
	
	public function Tab($id, $title, Canvas $c = null) {
		parent::Bones();
		
		$this->ID = $id;
		$this->title = $title;
		$this->pane = $c;
	}
	
	/**
	 * Implementation de object
	 * @see IRenderable::object()
	 */
	public function object() {
		return get_class($this);
	}

	/**
	 * Implementation de scLog
	 * @see IRenderable::properties()
	 */
	public function properties() {
		return parent::getProp($this);
	}

	/**
	 * Implementation de scLog
	 * @see IRenderable::scLog()
	 */
	public function scLog() {
		//
	}
	
	/**
	 * Implementation de render
	 * @see IScreen::render()
	 */
	public function render() {
		$this->scLog();
		return "{".$this->properties()."}";
	}
}
?>